// 字体图标 url
const CSSCDNUrlList: Array<string> = [
  // '//at.alicdn.com/t/font_2298093_y6u00apwst.css',
  // '//cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css',
  // '//cdn.jsdelivr.net/npm/remixicon@2.5.0/fonts/remixicon.css'
]
// 第三方 js url
const JSCDNUrlList: Array<string> = []

export default {
  setCSSCDN() {
    if (CSSCDNUrlList.length <= 0) return false
    CSSCDNUrlList.map((v) => {
      const link = document.createElement('link')
      link.rel = 'stylesheet'
      link.href = v
      link.crossOrigin = 'anonymous'
      document.getElementsByTagName('head')[0].appendChild(link)
    })
  },
  setJSCDN() {
    if (JSCDNUrlList.length <= 0) return false
    JSCDNUrlList.map((v) => {
      const link = document.createElement('script')
      link.src = v
      document.body.appendChild(link)
    })
  }
}
